.class Lrexsee/core/widget/TabButton$1;
.super Ljava/lang/Object;
.source "TabButton.java"

# interfaces
.implements Landroid/view/View$OnTouchListener;


# annotations
.annotation system Ldalvik/annotation/EnclosingMethod;
    value = Lrexsee/core/widget/TabButton;-><init>(Landroid/content/Context;Lrexsee/core/menu/PopMenuItem;)V
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x0
    name = null
.end annotation


# instance fields
.field final synthetic this$0:Lrexsee/core/widget/TabButton;


# direct methods
.method constructor <init>(Lrexsee/core/widget/TabButton;)V
    .locals 0

    .prologue
    .line 1
    iput-object p1, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    .line 12
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    return-void
.end method

.method private cancelPressed()V
    .locals 2

    .prologue
    .line 36
    iget-object v0, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v1, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v1, v1, Lrexsee/core/widget/TabButton;->styleNormal:Lrexsee/core/style/StyleSheet;

    iput-object v1, v0, Lrexsee/core/widget/TabButton;->styleSheet:Lrexsee/core/style/StyleSheet;

    .line 37
    iget-object v0, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    invoke-virtual {v0}, Lrexsee/core/widget/TabButton;->setLabelStyle()V

    .line 38
    return-void
.end method


# virtual methods
.method public onTouch(Landroid/view/View;Landroid/view/MotionEvent;)Z
    .locals 5
    .param p1, "v"    # Landroid/view/View;
    .param p2, "event"    # Landroid/view/MotionEvent;

    .prologue
    const/4 v4, 0x0

    .line 15
    invoke-virtual {p2}, Landroid/view/MotionEvent;->getAction()I

    move-result v0

    .line 16
    .local v0, "action":I
    if-nez v0, :cond_1

    .line 17
    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v4, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v4, v4, Lrexsee/core/widget/TabButton;->stylePressed:Lrexsee/core/style/StyleSheet;

    iput-object v4, v3, Lrexsee/core/widget/TabButton;->styleSheet:Lrexsee/core/style/StyleSheet;

    .line 18
    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    invoke-virtual {v3}, Lrexsee/core/widget/TabButton;->setLabelStyle()V

    .line 19
    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->downRunnable:Ljava/lang/Runnable;

    if-eqz v3, :cond_0

    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->downRunnable:Ljava/lang/Runnable;

    invoke-interface {v3}, Ljava/lang/Runnable;->run()V

    .line 33
    :cond_0
    :goto_0
    const/4 v3, 0x0

    return v3

    .line 20
    :cond_1
    const/4 v3, 0x1

    if-ne v0, v3, :cond_3

    .line 21
    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->styleSheet:Lrexsee/core/style/StyleSheet;

    iget-object v4, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v4, v4, Lrexsee/core/widget/TabButton;->stylePressed:Lrexsee/core/style/StyleSheet;

    invoke-virtual {v3, v4}, Ljava/lang/Object;->equals(Ljava/lang/Object;)Z

    move-result v3

    if-eqz v3, :cond_0

    .line 22
    invoke-direct {p0}, Lrexsee/core/widget/TabButton$1;->cancelPressed()V

    .line 23
    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->extraRunnable:Ljava/lang/Runnable;

    if-eqz v3, :cond_2

    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->extraRunnable:Ljava/lang/Runnable;

    invoke-interface {v3}, Ljava/lang/Runnable;->run()V

    .line 24
    :cond_2
    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->upRunnable:Ljava/lang/Runnable;

    if-eqz v3, :cond_0

    iget-object v3, p0, Lrexsee/core/widget/TabButton$1;->this$0:Lrexsee/core/widget/TabButton;

    iget-object v3, v3, Lrexsee/core/widget/TabButton;->upRunnable:Ljava/lang/Runnable;

    invoke-interface {v3}, Ljava/lang/Runnable;->run()V

    goto :goto_0

    .line 26
    :cond_3
    const/4 v3, 0x3

    if-ne v0, v3, :cond_4

    .line 27
    invoke-direct {p0}, Lrexsee/core/widget/TabButton$1;->cancelPressed()V

    goto :goto_0

    .line 28
    :cond_4
    const/4 v3, 0x2

    if-ne v0, v3, :cond_0

    .line 29
    invoke-virtual {p2}, Landroid/view/MotionEvent;->getX()F

    move-result v1

    .line 30
    .local v1, "x":F
    invoke-virtual {p2}, Landroid/view/MotionEvent;->getY()F

    move-result v2

    .line 31
    .local v2, "y":F
    cmpg-float v3, v1, v4

    if-ltz v3, :cond_5

    invoke-virtual {p1}, Landroid/view/View;->getWidth()I

    move-result v3

    int-to-float v3, v3

    cmpl-float v3, v1, v3

    if-gtz v3, :cond_5

    cmpg-float v3, v2, v4

    if-ltz v3, :cond_5

    invoke-virtual {p1}, Landroid/view/View;->getHeight()I

    move-result v3

    int-to-float v3, v3

    cmpl-float v3, v2, v3

    if-lez v3, :cond_0

    :cond_5
    invoke-direct {p0}, Lrexsee/core/widget/TabButton$1;->cancelPressed()V

    goto :goto_0
.end method
